package methodlocal;

public class MyOuter {
	private String x = "Outer2";

	void doStuff() {
		final String z = "local variable";
		class MyInner {
			public void seeOuter() {
				System.out.println("Outer x is " + x);
				System.out.println("Local variable z is: " + z); // Won't Compile if z not final!
			} // close inner class method
		} // close inner class definition
		MyInner mi = new MyInner(); // This line must come
		// after the class
		mi.seeOuter();
	} // close method doStuff()
	
	public static void main(String[] args) {
		MyOuter mo = new MyOuter();
		mo.doStuff();
	}
} // close outer class